<template>
	<scroll-view scroll-y class="bgf5 group c00" :style="{height: 'calc(100vh - 156rpx - ' + statusBar + 'px)'}">
		<view v-for="(item,index) in list" :key="index" class="rel px10 r6 py8 my10 mx16 shadow" :class="index < 0 ? 'bgf2' : 'bgff'">
			<view class="flex flexC fs12 box">
				<view class="px10 aliC borrd">
					<view class="cff0">
						<text class="fs12">时长</text>
						<text class="fs28 bold6">{{item.hour}}小时</text>
					</view>
					<view class="fs11">好评时长券</view>
				</view>
				<view class="flex1 pl10">
					<view class="fs13">{{item.shop.name}}可使用</view>
					
					<view class="c85 fs10 py5">有效期：{{item.valid_time_txt}}</view>
					
				</view>
				<image v-if="index > 2" class="passed" src="/static/img/bg/passed.png" mode="aspectFill"></image>
			</view>
		
		</view>
		
		
	</scroll-view>
</template>

<script>
	export default {
	
		data() {
			return {
				isChecked: false,
				page:1,
				list:[],
				currentItem:[],
				check:false
			};
		},
		onShow() {
			this.getData();
		},
		methods: {
			openItem2(){
				this.check = !this.check;
			},
			
			openItem(item){
				
				this.currentItem = item;
				this.$refs.popup.open();
			},
			
			getData() {
				
				let param = {
			
				};
				let that = this;
				this.$api.commentList(param).then(res => {
					console.info(JSON.stringify(res));
					if (res.code == 1) {
						that.list = res.data;
					} else {
				
					}
				})
				// this.$nextTick(() => {
				// 	this.$refs.popup.open();
				// })
			}
		}
	}
</script>

<style lang="scss" scoped>
.group {
	.rel {position: relative;}
	.bgf2 {
		color: #858585;
		.cff0 {
			color: #858585;
		}
	}
	.borrd {border-right: 4rpx dashed #eee;}
	.passed {
		width: 86rpx;
		height: 86rpx;
		position: absolute;
		top: 10rpx;
		right: 10rpx;
	}
	.box {
		.origin {text-decoration-line: line-through;}
	}
	.borbb {
		border-bottom: 4rpx dashed #eee;
	}
	.w10 {
		width: 20rpx;height: 12rpx;
		transform: rotate(90deg);
		transition: .5s;
		&.up {
			transform: rotate(180deg);
		}
	}
	.borb57 {border-bottom: 2rpx solid #576DAB;}
	.left {width: 200rpx;height: 100%;}
	.right {width: 300rpx;border-left: 2rpx solid #576DAB;}
}
</style>